﻿using Hegang.APP.Models;
using Hegang.APP.Models.DataBase;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Hegang.APP.Services.DbService.Impl
{
    class M_hum : DbServiceObject
    {
        public void save(DbObject o, ref DbServiceInput input)
        {
            string sql = string.Format(
                "INSERT INTO `m_hum` (`hum1`,`hum2`,`hum3`,`hum4`,`timeStamp`) VALUES ( '{0}','{1}','{2}','{3}','{4}');", 
                input.Dic["传感器.主井机柜.湿度1"], 
                input.Dic["传感器.主井机柜.湿度2"], 
                input.Dic["传感器.主井机柜.湿度3"], 
                input.Dic["传感器.主井机柜.湿度4"], 
                System.DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"));
            o.cmmdNoReturn(sql);
        }
    }
}
